Imports System.ComponentModel
Imports DotNetNuke.UI.WebControls
Imports Aricie.DNN.UI.WebControls.EditControls
Imports Aricie.DNN.UI.Attributes

Namespace Aricie.DNN.Caching.Client.Velocity
    <Serializable()> _
    Public Class VelocityClusterSettings
        Inherits CachingClusterSettings



        Private _CacheName As String = ""
        'Private _DefaultRegionName As String = ""

        Private _AutoCreateRegions As Boolean = True
        Private _PessimisticLockTimeout As New STimeSpan(TimeSpan.FromMinutes(10))


        <ExtendedCategory("AppFabricSettings")> _
        Public Property CacheName() As String
            Get
                Return _CacheName
            End Get
            Set(ByVal value As String)
                _CacheName = value
            End Set
        End Property



        <ExtendedCategory("AppFabricSettings")> _
        Public Property AutoCreateRegions() As Boolean
            Get
                Return _AutoCreateRegions
            End Get
            Set(ByVal value As Boolean)
                _AutoCreateRegions = value
            End Set
        End Property

        <ExtendedCategory("AppFabricSettings")> _
        <Editor(GetType(PropertyEditorEditControl), GetType(EditControl))> _
           <LabelMode(LabelMode.Top)> _
        Public Property PessimisticLockTimeout() As STimeSpan
            Get
                Return _PessimisticLockTimeout
            End Get
            Set(ByVal value As STimeSpan)
                _PessimisticLockTimeout = value
            End Set
        End Property



    End Class
End Namespace